import request from '.././request'
// card_header: 999
// card_type: 虚拟卡
// affiliation: 大客户
export const addCardNumber = function ({ card_header, card_type, affiliation }) {
    return request({
        url: 'addCardNumber',
        method: 'POST',
        data: {
            card_header,
            card_type,
            affiliation,
        }
    })
}

export const getCardNumber = function () {
    return request({
        url: 'getCardNumber',
        method: 'GET',

    })
}

export const findCardNumber = function (affiliation) {
    return request({
        url: 'findCardNumber',
        method: 'POST',
        data: {
            affiliation
        }
    })
}

export const findCardNumberByHeader = function (card_header) {
    return request({
        url: 'findCardNumber',
        method: 'POST',
        data: {
            card_header
        }
    })
}



export const updateCardNumber = function (id, card_header) {
    return request({
        url: 'updateCardNumber',
        method: 'POST',
        data: {
            id,
            card_header
        }
    })
}

export const deleteCardNumber = function (id) {
    return request({
        url: 'deleteCardNumber',
        method: 'POST',
        data: {
            id,
        }
    })
}
